<form id="add-form" class="form-horizontal" role="form" data-toggle="validator" method="POST" action="">
    <div class="form-group">
        <label class="control-label col-xs-12 col-sm-1">{:__('Year')}:</label>
        <div class="col-xs-12 col-sm-11">


            <select data-rule="required" class="form-control" name="row[year]">
                {volist name="years" id="vo"}
                    <option value="{$vo}">{$vo}</option>
                {/volist}

            </select>
        </div>
    </div>
    <div class="form-group">
        <label class="control-label col-xs-12 col-sm-1">{:__('Month')}:</label>
        <div class="col-xs-12 col-sm-11">

            <select data-rule="required" class="form-control" name="row[month]" id="month">
                {for start="1" end="13"}
                    <option value="{$i}" {if $i == date('m',time())} selected{/if}>{$i}</option>
                {/for}
            </select>
        </div>
    </div>
    <div class="form-group">
        <label class="control-label col-xs-12 col-sm-1">{:__('选择')}:</label>
        <div class="col-xs-12 col-sm-11">
            <table class="table table-bordered ">
                <tr class="choose">
                    <td width="20%">日</td>
                    <td width="40%">时间</td>
                    <td width="40%">商品</td>
                </tr>
                {for start="1" end="$lastDays"}
                <tr>
                    <td>
                        <input id="c-day" data-rule="required" class="form-control" name="row[day][]" type="text" value="{$i}" readonly>
                    </td>
                    <!--<td>-->
                        <!--<input id="c-time_id"  data-source="/admin/seckill/activity/index" data-field="name" class="form-control selectpage" name="row[time_id][]" type="text" value="">-->
                    <!--</td>-->
                    <!--<td>-->
                        <!--<input id="c-goods_ids" data-source="/admin/seckill/goods/index" data-field="name" data-multiple="true" class="form-control selectpage" name="row[goods_ids][]" type="text" value="">-->
                    <!--</td>-->

                    <td>
                        <select class="form-control" name="row[time_id][{$i}][]" id="c-time_id">
                            <option value="">请选择时间</option>
                            {foreach $times as  $vo}
                            <option value="{$vo['id']}">{$vo['name']}</option>
                            {/foreach}
                        </select>
                    </td>
                    <td>
                        <select class="form-control" name="row[goods_ids][{$i}][]" multiple='multiple' id="c-goods_ids">
                            <option value="">请选择商品</option>
                            {foreach $goods as $gvo}
                            <option value="{$gvo['id']}">{$gvo['name']}</option>
                            {/foreach}
                        </select>
                    </td>

                </tr>
                {/for}
            </table>
        </div>
    </div>
    <div class="form-group layer-footer">
        <label class="control-label col-xs-12 col-sm-2"></label>
        <div class="col-xs-12 col-sm-8">
            <button type="submit" class="btn btn-success btn-embossed disabled">{:__('OK')}</button>
            <button type="reset" class="btn btn-default btn-embossed">{:__('Reset')}</button>
        </div>
    </div>
</form>
